package Java学习.基础;

public class User {
    //属性
    private String username;
    private String password;
    private String email;
    private String gander;
    private int age;
    // 空参构造
    public User(){};
    //带全部参数的构造
    public User(String username,String password,
                String email,String gander,int age){
        this.username=username;
        this.password=password;
        this.email=email;
        this.gander=gander;
        this.age=age;

        //get和set方法.
    }

    public void setUsername(String username) {
        this.username = username;
    }
    public String getUsername() {
        return username;
    }

    public void setPassword(String password) {
        this.password = password;
    }
    public String getPassword(){
        return password;
    }
    public void setGander(String gander){
        this.gander=gander;
    }

    public String getGander() {
        return gander;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public int getAge() {
        return age;
    }
    //快捷键
    //alt+insert
    //alt+Fn+insert
}
